#!/usr/bin/env bash
cd /Workspace

tar zxvf memcache-2.2.6.tgz
cd memcache-2.2.6/
/tools/php/bin/phpize
./configure --with-php-config=/tools/php/bin/php-config
make && make instal

cp modules/memcache.so /tools/php/lib/php/extensions/memcache.so

echo 'extension=/tools/php/lib/php/extensions/memcache.so' >> ${PHP_INI}
